package com.yfp.operation.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.yfp.operation.domain.OrderDetailDO;
import com.yfp.operation.domain.dto.OrderDetailDTO;
import com.yfp.operation.domain.vo.OrderDetailVO;
import com.yfp.operation.domain.vo.OrderInfoVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 *
 * @description 针对表【order_detail】的数据库操作Mapper
 * @createDate 2024-04-19 16:44:44
 * @Entity com.yfp.operation.domain.OrderDetail
 */
@Mapper
public interface OrderDetailMapper extends BaseMapper<OrderDetailDO> {

    List<OrderDetailVO> getDetail(String orderSn);

    Long getYesterdayCount(String orderSn);

    List<OrderDetailDO> listTodayInTheMakingWorkOrderIsNull();

    List<OrderDetailDTO> listTodayWorkOrderIsNull();

    OrderDetailDO findByOrderDetailId(@Param("orderDetailId") String orderDetailId);

    List<OrderInfoVO> getByOrderId(String orderId);

    /**
     * 修改订单状态
     * @param orderId
     * @param status
     */
    void editStatusByOrderId(@Param("orderId")String orderId, @Param("status")String status);
}
